home *** CD-ROM | disk | FTP | other *** search
- #ifndef __LISTCODE__
- #define __LISTCODE__
-
-
- #include <Lists.h>
- #include <Windows.h>
- #include <Events.h>
- #include <Drag.h>
-
-
-
- // Utilities
-
- void GlobalToLocalRect(Rect *r);
- void LocalToGlobalRect(Rect *r);
- void GetGlobalMouse(Point *mouse);
-
- Boolean HandleListClick(WindowPtr win, EventRecord *event);
- void GetRectHeight(WindowPtr win, short rows, short *height);
- Boolean MouseHitSelection(ListHandle list, Point localPt);
- Boolean GetFirstSelection(ListHandle list, Cell *cell);
- void UpdateFrameList(ListHandle list);
- Boolean EqualCells(Cell c1, Cell c2);
- Boolean GetSelectionRect(ListHandle list, Rect *rct);
- Boolean MyClickLoop();
-
-
-
- // Source list specific
-
- void AddToSourceList(OSType theType);
- void BuildSourceList(WindowPtr win);
- void HandleClickInSourceList(WindowPtr win,
- Boolean newClick, Boolean doubleClick, Cell nuCell);
- void UpdateSourceList();
-
-
- // Dest list specific
-
- void AddToDestList(OSType theType);
- void BuildDestList(WindowPtr win);
- void HandleClickInDestList(WindowPtr win,
- Boolean newClick, Boolean doubleClick, Cell nuCell);
- void UpdateDestList();
- Boolean PtInDestList(Point localPt);
- void GetDestListRect(Rect *rct);
-
-
-
- // Drag & Drop specific
-
- #define myPersonalFlavorType 'Type'
-
- OSErr StartADrag(ListHandle list, EventRecord *theEvent);
- OSErr AddFlavors(DragReference drag, ItemReference item,
- ListHandle list);
- void OutlineRegion(RgnHandle theRgn);
-
-
-
- #endif